package com.broheim.websocket.server.config;

import com.broheim.websocket.core.listener.HeartbeatListener;
import com.broheim.websocket.spring.config.ListenerRegisterBean;
import org.springframework.context.annotation.Bean;
import org.springframework.context.annotation.Configuration;

@Configuration
public class WebSocketConfig {

    @Bean
    public ListenerRegisterBean listenerRegisterBean() {
        ListenerRegisterBean listenerRegisterBean = new ListenerRegisterBean();
        listenerRegisterBean.registerListener("/test", new HeartbeatListener());
        return listenerRegisterBean;
    }
}
